package com.pgytesting.secondhandcar.model;

import java.util.Date;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

import org.hibernate.validator.constraints.Length;

import lombok.Data;
import com.fasterxml.jackson.annotation.JsonInclude;

import java.io.Serializable;

/**
 * 管理员信息表(AdministratorInformation)实体类
 *
 * @author makejava
 * @since 2019-08-15 10:07:12
 */
@Data
@JsonInclude(JsonInclude.Include.NON_NULL)   // 注解对对象空值进行json互转时的null值进行移除
public class AdministratorInformation implements Serializable {
    //ID
    private Integer id;
    //用户名
    @NotNull(message = "用户名不能为空")
    private String userNumber;
    //密码
    @NotNull(message = "密码不能为空")
    //@Length(min = 6, message = "密码不能少于6位")
    @Pattern(regexp = "^[0-9a-zA-Z_]{6,}$", message = "密码为字母数字_组成，且不能少于6位")
    private String password;
    //角色id
    private Integer roleId;
    //创建人
    private String createdBy;
    //创建时间
    private Long createdTime;
    //更新人
    private String updatedBy;
    //更新时间
    private Long updatedTime;
    //状态 -1为删除或者异常，默认为0
    private Integer status;


}